package com.sean.stock.service.impl;

import com.sean.stock.entity.Stock;
import com.sean.stock.mapper.StockMapper;
import com.sean.stock.service.IStockService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

/**
 * @author Sean
 */
@Service
public class StockServiceImpl implements IStockService {
    @Resource
    private StockMapper stockMapper;

    @Override
    public void reduce(Long productId) {
        stockMapper.reduceByProductId(productId);
    }
}
